
export const getToken = ()=>{
 return sessionStorage.getItem("token")
}

export const getCompany_id = ()=>{
 return parseInt(sessionStorage.getItem("company_id")??"0")
}

export const setCompany_id = (company_id:number)=>{
 sessionStorage.setItem("company_id", company_id.toString())
}

export const setUser_id = (user_id:number)=>{
 sessionStorage.setItem("user_id", user_id.toString())
}

export const getUser_id = ()=>{
 return parseInt(sessionStorage.getItem("user_id")??"0")
}

export const setUser_name = (user_name:string)=>{
 sessionStorage.setItem("user_name", user_name.toString())
}

export const getUser_name = ()=>{
 return (sessionStorage.getItem("user_name")??`游客`)
}

